<template>
  <div class="inputCtx">
    <el-date-picker
      v-bind="$attrs"
      v-model="value"
      :append-to-body="false"
      type="datetimerange"
      @change="change"
      range-separator="至"
      start-placeholder="开始日期"
      end-placeholder="结束日期"
    >
    </el-date-picker>
  </div>
</template>

<script>
import mixins from "./mixins.js";
export default {
  mixins: [mixins],
  data() {
    return {
      value: "",
    };
  },
  methods: {
    change(e) {
      this.updateFilter(e);
      this.updateValue(e);
      this.closePopover();
    },
  },
};
</script>

<style scoped lang="less">
.inputCtx {
  display: flex;
}
</style>
